package com.xml2db;

import java.util.ArrayList;
import java.util.List;

/**
 * 
 * 数据表实体(有表名，字段名，类型，数据)
 * 
 * @author levy
 *
 */
public class DBTable {

	/** 表名 */
	private String tableName;
	/** 字段名 */
	private List<String> fields = new ArrayList<String>();
	/** 字段类型 */
	private List<String> fieldsTypes = new ArrayList<String>();
	/** 每行数据 */
	private List<Object[]> datas = new ArrayList<Object[]>();// 装载每行数据

	public String getTableName() {
		return tableName;
	}

	public void setTableName(String tableName) {
		this.tableName = tableName;
	}

	public void addField(String field) {
		this.fields.add(field);
	}

	public void addFieldType(String fieldType) {
		this.fieldsTypes.add(fieldType);
	}

	public void addData(String[] o) {
		datas.add(o);
	}

	public List<String> getFields() {
		return fields;
	}

	public void setFields(List<String> fields) {
		this.fields = fields;
	}

	public List<String> getFieldsTypes() {
		return fieldsTypes;
	}

	public void setFieldsTypes(List<String> fieldsTypes) {
		this.fieldsTypes = fieldsTypes;
	}

	public List<Object[]> getDatas() {
		return datas;
	}

	public void setDatas(List<Object[]> datas) {
		this.datas = datas;
	}

}